package com.cxs.service.impl;

import com.cxs.mapper.OutPatientTypeMapper;
import com.cxs.pojo.OutPatientType;
import com.cxs.service.OutPatientTypeService;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/*
 * @Author:cxs
 * @Date:2021/10/22  9:43
 * @Version 1.0
 * @Motto:放下杂念,只为迎接明天更好的自己
 * */
@Service
public class OutPatientTypeServiceImpl implements OutPatientTypeService {

    @Autowired
    private OutPatientTypeMapper outPatientTypeMapper;

    @Override
    public PageInfo<OutPatientType> patientInfoPage(String proName, Integer pageNo, Integer pageSize) {
        PageHelper.startPage(pageNo,pageSize);
        List<OutPatientType> patientTypeList = outPatientTypeMapper.selectListByName(proName);
        return new PageInfo<OutPatientType>(patientTypeList);
    }
}
